<template>
	<div class="resume">
		<Header></Header>
    <div class="resume-main flex">
      <div class="resume-left">
        <meNav :resumeData="resumeData"></meNav>
      </div>
      <div class="resume-right">
        <personal :resumeInfos="resumeData.resumeInfos"/>
        <div class="row-line"></div>
        <jobIntention :resumeIntentions="resumeData.resumeIntentions"/>
        <div class="row-line"></div>
        <selfDesc :resumeSelfDescs="resumeData.resumeSelfDescs"/>
        <div class="row-line"></div>
        <education :resumeEducations="resumeData.resumeEducations"/>
        <div class="row-line"></div>
        <workExperience :resumeWorks="resumeData.resumeWorks"/>
        <div class="row-line"></div>
        <trainingExperience :resumeTrains="resumeData.resumeTrains"/>
        <div class="row-line"></div>
        <certificate :resumeCertificates="resumeData.resumeCertificates"/>
        <div class="row-line"></div>
        <language :resumeLanguages="resumeData.resumeLanguages"/>
        <div class="row-line"></div>
        <specialty :resumeSpecialtyTags="resumeData.resumeSpecialtyTags"/>
        <div class="row-line"></div>
        <opus :resumeProducts="resumeData.resumeProducts"/>
        <!-- <div class="row-line"></div>
        <enclosure :resumeAttachments="resumeData.resumeAttachments"/> -->
        <!-- <div class="save-all" @click="goToPreview">保存简历</div> -->
      </div>
    </div>
    <Footer></Footer>
	</div>
</template>
<script>
  import {getResume} from '@/api/me/resume'
  import Header from '@/views/components/header/header'
  import Footer from '@/views/components/header/footer'
  import meNav from '@/views/components/me/resume/nav'
  import personal from '@/views/components/me/resume/personal'
  import jobIntention from '@/views/components/me/resume/job-intention'
  import selfDesc from '@/views/components/me/resume/self-desc'
  import education from '@/views/components/me/resume/education'
  import workExperience from '@/views/components/me/resume/work-experience'
  import trainingExperience from '@/views/components/me/resume/training-experience'
  import certificate from '@/views/components/me/resume/certificate'
  import language from '@/views/components/me/resume/language'
  import specialty from '@/views/components/me/resume/specialty'
  import opus from '@/views/components/me/resume/opus'
  // import enclosure from '@/views/components/me/resume/enclosure'
	export default {
    name:'resume',
		data(){
			return {
        id:this.$route.query.id,
        resumeData:{
          resumeName: "",
          defaultResume: 0,
          resumeInfos: [],
          resumeIntentions: [],
          resumeSelfDescs: [],
          resumeEducations: [],
          resumeWorks: [],
          resumeTrains: [],
          resumeCertificates: [],
          resumeLanguages: [],
          resumeSpecialtyTags: [],
          resumeProducts: [],
          resumeAttachments: [],
        }
			}
		},
		watch: {

    },
    components:{Header,Footer,meNav,personal,jobIntention,selfDesc,education,workExperience,trainingExperience,certificate,language,specialty,opus},
		created() {
      this.getResumeInfo();
		},
		methods: {
			getResumeInfo(){
        var data={id:this.id};
        getResume(data).then(res => {
            this.resumeData=res.datas;
        }).catch(err => {
            this.$message.error(err);
        })
      },
      goToPreview(){
				this.$router.push({ path:"/resumePreview" ,query:{id:this.id}});
			}
    }
	}
</script>
<style lang="scss" scoped="scoped">
.header {

    >>>.top{
        background: #3B4D66;
    }
    >>>.nav {
        background:#435772;
    }
}
  .resume{
    width: 100%;
    .resume-main{
      width: 1200px;
      padding: 35px 0;
      margin-left: auto;
      margin-right: auto;
      min-height: 700px;
      .resume-left{
        width: 210px;
      }
      .resume-right{
        width: 960px;
        margin-left: 20px;
        background-color: #fff;
        padding: 30px 30px;
        box-sizing: border-box;
        .row-line{
          width: 100%;
          border-bottom: 1px dashed #E0E0E0;
        }
        .save-all{
          width: 170px;
          height: 40px;
          background: #3EACC4;
          border-radius: 4px;
          color: #fff;
          text-align: center;
          line-height: 40px;
          margin-left: auto;
          margin-right: auto;
          margin-top: 100px;
          margin-bottom: 40px;
          cursor: pointer;
        }
      }
    }
  }
</style>
